package org.oneboot.core.lang;

import java.util.Collection;
import java.util.Map;

import org.springframework.lang.Nullable;
import org.springframework.util.CollectionUtils;
import org.springframework.util.ObjectUtils;

public class ListUtils {
	/**
	 * array 是否为空
	 * 
	 * @param array
	 */
	public static boolean isEmpty(@Nullable Object[] array) {
		return ObjectUtils.isEmpty(array);
	}

	/**
	 * List 是否为空
	 * 
	 * @param list
	 * @return
	 */
	public static boolean isEmpty(@Nullable Collection<?> list) {
		return CollectionUtils.isEmpty(list);
	}

	/**
	 * Map 是否为空
	 * 
	 * @param map
	 * @return
	 */
	public static boolean isEmpty(@Nullable Map<?, ?> map) {
		return CollectionUtils.isEmpty(map);
	}
}
